home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus Extra 1997 #4
/
Amiga Plus Extra 1997 #4.iso
/
pd
/
grafik
/
video easel
/
camrexx
/
isingi.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1997-06-09
|
520b
|
21 lines
/* Microcannonical Ising Model, by an idea of Toffoli, in CAMRexx by THOR */
MakeAlgorithm:
PLANEALGORITHM neumann hvphases
return
MakePlane:
lattice=(horz=vert)
if phase=1 then lattice=~lattice
/* handle only even or odd sublattice */
if lattice then; do
sum=north+south+east+west
if sum=2 then new=~center /* flip spin if two nbrs. */
else new=center /* else preserve */
SETPLANE new
end; else; do;
SETPLANE center
end
return